package net.osin.playscalajs.TableControl

object Util {
  def pagination(page_index: Int, page_size: Int, totalCount: Int) =
  {
    var start = page_size * (page_index - 1) + 1
    var end = start + page_size
    if (end >= totalCount)
      end = totalCount
    (start, end)
  }
}
